﻿Imports System.Data
Imports System.Data.OleDb
Public Module DataAccess
    Dim connectString As String = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\Lap trinh UDQL 2\DoAnQuanLyGara\QuanLyGara\QuanLyGara\Database1.mdb"

    Public Function TaoKetNoi() As OleDbConnection
        'tao ket noi
        Dim con As OleDbConnection = New OleDbConnection(connectString)
        'mo ket noi
        con.Open()
        Return con
    End Function
End Module
